// counterSlice.js
import { createSlice } from "@reduxjs/toolkit";

const counterSlice = createSlice({
    name: "userInfo",
    initialState: {
        user: {
            name: "张三",
        },
        theme: "dark",
    },
    reducers: {},
});

// export const { increment, decrement } = counterSlice.actions;
export const getTheme = (state: { userInfo: { theme: any } }) => state.userInfo.theme;

export default counterSlice.reducer;
